home *** CD-ROM | disk | FTP | other *** search
- Subject: Re: Save Command
- Sent: 6/25/96 3:18 AM
- Received: 6/25/96 10:33 AM
- From: Richard Rodseth, rodseth@apple.com
- Reply-To: ODF Interest, ODF-Interest@CILabs.ORG
- To: OpenDoc Development Framework Discussion List, ODF-Interest@CILabs.
-
- >I have a palette icon button that is used to save the current document (a
- >customer request). When this button is pressed, I need to tell OpenDoc
- >to save the document with the default name (same as cmd-S) in my frame's
- >HandleNotification method. What is the preferred method to perform this
- >task, given the customer requirements?
-
- John,
-
- I hope others will weigh in with their opinions. Unfortunately, I don't
- think there is currently a clean way to do this. On the Mac, You could
- make up a dummy menu event record and call ODDispatcher::Dispatch().
- You'd need to set the "what" field to kODEvtMenu, ask the current menu
- bar for the menu and item number corresponding to the save command, and
- put them in the high and low word of the message field, respectively.
- Ouch!
-
- OpenDoc should probably provide a cleaner way. Perhaps a shell API or a
- set of AppleEvent handlers, and utilities to send the events. The problem
- is that a container app would have to support these too.
-
- Richard Rodseth
-
-
-
-
-
- "It's no use prevaricating about the bush"
- - Wallace, in "The Wrong Trousers"
-